package com.twu.biblioteca.Model;

import com.twu.biblioteca.Entity.User;

import java.util.HashMap;
import java.util.Map;

public class UserList {

    private static Map<String, User> userList = new HashMap<String, User>();
    private static User loginUser = null;

    public UserList() {
        userList.put("123-1234", new User("123-1234", "Tom", "tom@thoughtworks.com", "1234567", "111111"));
        userList.put("234-2345", new User("234-2345", "Lucy", "lucy@thoughtworks.com", "7654321", "222222"));
    }

    public Map<String, User> getUserList() {
        return userList;
    }

    public User getLoginUser() {
        return loginUser;
    }

    public void setLoginUser(User loginUser) {
        UserList.loginUser = loginUser;
    }
}
